<template>
    <div>
        <el-input v-model="computedVal" autocomplete="off" :placeholder="placeholder" :type="type"></el-input>
    </div>
</template>

<script>
export default {
    name: 'CommonInput',
    props: {
        value: [String, Number],
        placeholder: [String],
        type: {
            type: String,
            default: 'text'
        }
    },
    data() {
        return {

        };
    },
    computed: {
        computedVal: {
            get() {
                return this.value
            },
            set(v) {
                this.$emit('input', v)
            }
        }
    },
    mounted() {

    },

    methods: {

    },
};
</script>

<style lang="less" scoped>
.el-textarea {

    // margin-left: 10px;
}

.el-input {
    height: 32px;
    // margin-left: 10px;
    width: 220px;

    ::v-deep(.el-input__inner) {
        border-radius: 2px;
        height: 32px;
        line-height: 32px;
    }

    ::v-deep(.el-input__suffix) {
        display: grid;
        place-content: center;
    }

    ::v-deep(.el-range-editor.is-active,
        .el-range-editor.is-active:hover,
        .el-input .el-input.is-focus .el-input__inner) {
        border-color: #fc740c;
    }

    ::v-deep {


        .el-input__inner:focus {
            border-color: #fc740c;

        }
    }
}
</style>